home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 1
/
Cream of the Crop 1.iso
/
PROGRAM
/
DBVGAL17.ARJ
/
DEMOS.ARJ
/
L40.ASM
< prev
next >
Wrap
Assembly Source File
|
1992-01-25
|
2KB
|
61 lines
name _L40set
; void L40set(void);
L40_TEXT segment byte public 'CODE'
assume cs:L40_TEXT
org 100h
_L40set:
mov ax,1202h ; scanline = 400
mov bl,30h
int 10h
cmp al,12h
jne @out ; bailout if not VGA
MOV AX,0003 ; textmode 0x03
INT 10h
MOV AX,1111h ; 8x14 char set & video parameters
MOV BL,00
INT 10h
MOV AX,1102h ; set 8 point font
MOV BL,00
INT 10h
mov dx,03d4h ; update CRTC register 9
mov al,09h
out dx,al
inc dx
in al,dx
and al,0e0h
or al,09h
out dx,al
mov dx,03d4h ; update CRTC register 12h
mov ax,9012h
out dx,ax
push ds
XOR AX,AX
MOV DS,AX
mov ah,09
MOV ds:[0485h],ah ; update BIOScrtpoints
mov ah,27h
MOV ds:[0484h],ah ; update BIOScrtrows
mov ah,40h
mov ds:[044dh],ah ; set page length to 16k
xor ah,ah
mov ds:[044ch],ah
pop ds
xor al,al
mov ah,1
mov ch,9
mov cl,0ah
int 10h ; set cursor size
@out:
mov ax,4c00h
int 21h
L40_TEXT ends
end _L40set